{extend name="public/base" /}

{block name="body"}
    <div class="main-title">
        <h2>{$meta_title}</h2>
    </div>
    <form action="{:url()}" method="post" class="form-horizontal">
    	<div class="form-item">
            <label class="item-label">选择课程 *</label>
            <div class="controls">
	            <select name="course_id" class="select2 input-large">
					{volist name=":get_student_course_list($_info['student_id'], $_info['course_id'])" id="vo"}
						<option value="{$key}" {eq name="_info.course_id" value="$key"}selected{/eq}>{$vo}</option>
					{/volist}
				</select>
			</div>
        </div>
        
        <div class="form-item">
            <label class="item-label">总课时<span class="check-tips">（总课时,单位小时）</span></label>
            <div class="controls">
                <input type="text" class="text input-large" name="total_hours" value="{$_info.total_hours}">
            </div>
        </div>
        <div class="form-item">
            <label class="item-label">剩余课时<span class="check-tips">（剩余课时,单位小时）</span></label>
            <div class="controls">
                <input type="text" class="text input-large" name="remain_hours" value="{$_info.remain_hours}">
            </div>
        </div>
        
        <div class="form-item">
            <label class="item-label">截止时间<span class="check-tips">（截止时间,选择时间）</span></label>
            <div class="controls">
                <input id="end_time" type="text" class="text input-large" name="end_time" value="{$_info.end_time}">
            </div>
        </div>
        
		
        <div class="form-item">
        	<label class="item-label"></label>
        	<input type="hidden" name="id" value="{$_info.id}"/>
        	<input type="hidden" name="student_id" value="{$_info.student_id}"/>
            <button class="btn submit-btn ajax-post" id="submit" type="submit" target-form="form-horizontal">确 定</button>
            <button class="btn btn-return" onclick="javascript:history.back(-1);return false;">返 回</button>
        </div>
    </form>
{/block}

{block name="script"}
<script src="__PUBLIC__/static/laydate/laydate.js"></script>
    <script type="text/javascript">
    	laydate({
    		format: 'YYYY-MM-DD hh:mm:ss',
			elem: '#end_time',
			min: laydate.now(), //-1代表昨天，-2代表前天，以此类推
			istime: true,
		});

    	Think.setValue("gender", {$_info.gender|default=0});
    	Think.setValue("state", {$_info.state|default=1});
        //导航高亮
        highlight_subnav('{:url('Student/index')}');
    </script>
{/block}
